package itdep.domain.education;

import ga.hibernate.OrderedEnum;
import ga.i18n.Translatable;
import itdep.domain.TranslationType;

import java.util.Collection;

/**
 * @author Ivan Khalopik
 * @version $Revision: 11 $ $Date: 2010-06-16 10:18:57 +0000 (Wed, 16 Jun 2010) $
 */
public enum ControlType implements OrderedEnum, Translatable {
	OFFSET(0, "offset"),
	EXAM(1, "exam"),
	DIFFERENTIAL_OFFSET(2, "differential-offset"),
	COURSE_PROJECT(3, "course-project"),
	COURSE_WORK(4, "course-work"),
	PRACTICE_OFFSET(5, "practice-offset"),
	PRACTICE_EXAM(6, "practice-exam"),
	ELECTIVE_OFFSET(7, "elective-offset"),
	ELECTIVE_EXAM(8, "elective-offset"),
	SECONDARY_EXAM(9, "exam"),
	DIPLOMA(10, "diploma");

	private TranslationType translationType = TranslationType.ABBREV;
	private String type = "control-type";
	private int order;
	private String code;

	ControlType(int order, String code) {
		this.order = order;
		this.code = code;
	}

	public int getOrder() {
		return order;
	}

	public String getTranslationType() {
		return type;
	}

	public String getTranslationCode() {
		return code;
	}

	public Collection<String> getTranslationVariants() {
		return translationType.getVariants();
	}
}
